Eitan Hersh
*Study Part I
*Overt Antisemitic Attitudes

cd C:\Users\ehersh01\Dropbox\antisemitism\replication



u TUFT0009_OUTPUT.DTA, clear

merge m:1 inputstate using pct_jew_pop
drop _merge
recode q2_mult* (2=0)
ren q2_mult_1 socialist
ren q2_mult_2 leftist
ren q2_mult_3 progressive
ren q2_mult_4 libertarian
ren q2_mult_5 alt_right
ren q2_mult_6 christian_con

gen college_4yr = 1 if q1 == 2 | q1 == 3
recode college .=0
gen college_degree  = 1 if educ == 5 | edu == 6
recode college_degree . =0
gen BA = 1 if college_degree ==1 | college_4yr == 1
recode BA . =0
gen no_identity = 1 if socialist == 0 & leftist == 0 & progres == 0 & liber == 0 ///
& alt_r == 0 & christ == 0
recode no_identity .=0


*controlling for previous randomizations
gen Q5_1 = 1 if Q5_7 == 1
gen Q5_2 = 1 if Q5_7 == 2
recode Q5_1 Q5_2 (.=0)
gen Q8_1 =1 if Q8_13 == 1
gen Q8_2 = 1 if Q8_13 ==2
recode Q8_1 Q8_2 (.=0)
gen Q14_1 =1 if Q14_15 == 1
recode Q14_1 .=0

*THese vars are Q5_1 Q5_2 Q8_1 Q8_2 Q14_1



gen prime_israel = Q16 == 2

gen black = race == 2
gen hisp = race == 3
gen white = race == 1
gen asian = race == 4
gen other_race =1 if race >4
replace other_race = 0 if race <=4
*Combining Asians and others
replace other_race = 1 if asian ==1 

gen female = gende == 2



gen loyal = q18
recode loyal  1 2 = 1 3 4 5 =0

gen boycott = q19
recode boycot 1 2 = 1 3 4 5 = 0

gen power = q20
recode power 1 2 =1 3 4 5 = 0

egen tot_ant = rowtotal(loyal boycott power)

gen antisem_geq1 = 1 if loyal ==1 | boycott == 1 | power == 1
replace antisem = 0 if loyal == 0 & boycott == 0 & power == 0



****************************
gen vlib = ideo7 == 1
gen mlib = ideo7 == 2
gen slib = ideo7 == 3
gen scon = ideo7 == 5
gen mcon = ideo7 == 6
gen vcon = ideo7 == 7
recode vlib-vcon (0=.) if ideo7 ==. 
gen mod = ideo7 == 4
recode mod 0=. if ideo7 == .

gen prime_vlib = prime_is*vlib
gen prime_mlib  = prime_is*mlib
gen prime_slib = prime_is*slib
gen prime_scon = prime_is*scon
gen prime_mcon = prime_is*mcon
gen prime_vcon = prime_is*vcon

label var vlib "Very Lib."
label var mlib "Liberal"
label var slib "Mod. Lib."
label var scon "Mod. Con."
label var mcon "Conservative"
label var vcon "Very Con."
label var prime_is "Prime"
label var prime_vlib "Prime x V.Lib"
label var prime_mlib "Prime x Lib"
label var prime_slib "Prime x M.Lib"
label var prime_scon "Prime x M.Con"
label var prime_mcon "Prime x Con"
label var prime_vcon "Prime x V.Con"
label var pct_jew "State Pct. Jew"
label var black "Black"
label var his "Latinx"
label var asia "Asian"
label var other_r "Other Race"
label var age "Age"
label var college_4 "4-year College"
label var college_degree "College Deg."
label var BA "College"
label var fema "Female"
label var loyal "Loyal"
label var boycott "Boycott"
label var power "Power"

*****DESCRIPTIVE STAT TABLE****
sum vlib-mod [aw=weight_a]
sum socialist-chri [aw=weight_a]
sum black hisp white other_ra pct_jew femal BA  age [aw=weight_a]

sum vlib-mod [aw=weight_o]
sum socialist-chri [aw=weight_o]
sum black hisp white other_ra  pct_jew femal BA age [aw=weight_o]


replace age = age/10


**HYPOTHESIS 1 and 2

bysort ideo7: ci mean loyal boycott power  if Q16 ==1  [aw=weight_o]
bysort ideo7: ci mean loyal boycott power  if Q16 ==2  [aw=weight_o]
*These stats are copied into paper_graph1.csv. See code below for generating figure.

*TABLE 1 (this is actually Table 2 in the paper)

reg loyal vlib-vcon prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paper, replace label excel 2aster auto(2) par(se) depvar drop(pct_jew black his other_race age femal  BA Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paper, label excel 2aster auto(2) par(se) depvar drop(pct_jew black his other_race age femal  BA Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon  prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 [aw= weight_o]
outreg2 using tab1_paper, label excel 2aster auto(2) par(se) depvar drop(pct_jew black his other_race age femal BA Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)


*TABLE 1 SI - showing demographics. Again, this is actually Tab 2)
reg loyal vlib-vcon prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paperSI, replace label excel 2aster auto(2) par(se) depvar drop(vlib-vcon prime_is prime_vlib-prime_vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 )
reg boycott vlib-vcon prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paperSI, label excel 2aster auto(2) par(se) depvar drop(vlib-vcon prime_is prime_vlib-prime_vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 )
reg power vlib-vcon  prime_is prime_vlib-prime_vcon pct_jew black his other_race age femal BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 [aw= weight_o]
outreg2 using tab1_paperSI, label excel 2aster auto(2) par(se) depvar drop(vlib-vcon prime_is prime_vlib-prime_vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

*TABLE 1 SI - Alt version of Table 1 (Table 2)
*ALT 1
label var socialist "Socialist"
label var leftist "Leftist"
label var progressive "Progressive"
label var liber "Libertarian"
label var alt "Alt Right"
label var christ "Christian Conserv."

reg loyal ideo7 socialist-christ  pct_jew black his other_race age femal  BA prime_is  Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paperSI_ALT, replace label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott ideo7 socialist-christ  pct_jew black his other_race age femal BA prime_is   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_o]
outreg2 using tab1_paperSI_ALT, label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power ideo7 socialist-christ  pct_jew black his other_race age femal  BA prime_is   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 [aw= weight_o]
outreg2 using tab1_paperSI_ALT, label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)




***HYPOTHESIS 3 and 4 - AGE

gen ageleq30  = 1 if age <= 3
replace ageleq30 = 0 if age >3



*TABLE 3
sum loyal boycott power  [aw=weight_a]
sum loyal boycott power   if age >3 [aw=weight_o]



ttesti 2429  .195424   .3966084 746 .2286546    .420248
ttesti  2429 .1739917   .3791804    746  .1105188   .3137456
ttesti 2430 .1317916   .3383337  746   .103115   .3043131  

*TABLE 3 - this is actually Table 4 in the paper

reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper, replace label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3  [aw= weight_o]
outreg2 using tab3_paper,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3   [aw= weight_o]
outreg2 using tab3_paper,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if age >3  [aw= weight_o]
outreg2 using tab3_paper,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

*TABLE 3 SI

reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI, replace label excel 2aster auto(2) par(se) depvar drop(vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3  [aw= weight_o]
outreg2 using tab3_paper_SI,  label excel 2aster auto(2) par(se) depvar drop(vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI,  label excel 2aster auto(2) par(se) depvar drop(vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3   [aw= weight_o]
outreg2 using tab3_paper_SI,  label excel 2aster auto(2) par(se) depvar drop(vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI,  label excel 2aster auto(2) par(se) depvar drop(vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if age >3  [aw= weight_o]
outreg2 using tab3_paper_SI,  label excel 2aster auto(2) par(se) depvar drop( vlib-vcon Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

*TABLE 3 SI - ALT
reg loyal ideo7 socialist-christ  prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI_ALT, replace label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg loyal ideo7 socialist-christ prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3  [aw= weight_o]
outreg2 using tab3_paper_SI_ALT,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott ideo7 socialist-christ prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI_ALT,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott ideo7 socialist-christ prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3   [aw= weight_o]
outreg2 using tab3_paper_SI_ALT,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power ideo7 socialist-christ prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paper_SI_ALT,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power ideo7 socialist-christ pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if age >3  [aw= weight_o]
outreg2 using tab3_paper_SI_ALT,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

*TABLE 3 SI - ALT 2 - STUDENTS
reg loyal vlib-vcon prime_is pct_jew black his other_race age femal     Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if college_4yr == 1 [aw= weight_a]
outreg2 using tab3_paper_SI_ALT2, replace label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal    Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if college_4yr == 1 [aw= weight_a]
outreg2 using tab3_paper_SI_ALT2,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vlib-vcon prime_is pct_jew black his other_race age femal    Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if college_4yr == 1 [aw= weight_a]
outreg2 using tab3_paper_SI_ALT2,  label excel 2aster auto(2) par(se) depvar drop( pct_jew black his other_race age femal  BA prime_is Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

bysort ideo7: ci mean loyal boycott power   [aw=weight_a]
bysort ideo7: ci mean loyal boycott power  if age >3 [aw=weight_o]
*These stats are copied into paper_graph1.csv. See code below for generating figure.


*Version with PID3
gen dem = pid3 
recode dem  1=1 nonmis = 0 
gen rep = pid3
recode rep 2=1 nonmis =0 
gen ind = pid3
recode ind 3 4 5 = 1 1 2 =0 

gen vdem = pid7
gen mdem = pid7
gen ldem = pid7
gen ind7 = pid7
gen lrep = pid7
gen mrep = pid7
gen vrep = pid7

recode vdem 1 =1 nonmis = 0
recode mdem 2=1 nonmis = 0
recode ldem 3=1 nonmis =0 
recode ind7 4 8 = 1 nonmis =0
recode lrep 5 =1 nonmis = 0
recode mrep 6=1 nonmis =0 
recode vrep 7=1 nonmis =0 


reg loyal vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paperpid, replace label excel 2aster auto(2) par(se) depvar drop( Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg loyal vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3  [aw= weight_o]
outreg2 using tab3_paperpid,  label excel 2aster auto(2) par(se) depvar drop( Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paperpid,  label excel 2aster auto(2) par(se) depvar drop(Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg boycott vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if age >3   [aw= weight_o]
outreg2 using tab3_paperpid,  label excel 2aster auto(2) par(se) depvar drop(Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  [aw= weight_a]
outreg2 using tab3_paperpid,  label excel 2aster auto(2) par(se) depvar drop( Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)
reg power vdem mdem ldem lrep mrep vrep prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if age >3  [aw= weight_o]
outreg2 using tab3_paperpid,  label excel 2aster auto(2) par(se) depvar drop( Q5_1 Q5_2 Q8_1 Q8_2 Q14_1)

sum antisem_geq if dem == 1 [aw=weight_a]
sum antisem_geq  if ind == 1 [aw=weight_a]
sum antisem_geq  if rep == 1 [aw=weight_a]

sum antisem if ideo7 <= 3 [aw=weight_a]
sum antisem if ideo7 == 4 [aw=weight_a]
sum antisem if ideo7 >=5 & ideo7 != . [aw=weight_a]

sum antisem_geq if dem == 1 & age > 3 [aw=weight_o]
sum antisem_geq  if ind == 1 & age > 3 [aw=weight_o]
sum antisem_geq  if rep == 1  & age > 3 [aw=weight_o]

sum antisem if ideo7 <= 3 & age > 3 [aw=weight_o]
sum antisem if ideo7 == 4 & age > 3 [aw=weight_o]
sum antisem if ideo7 >=5 & ideo7 != . & age > 3 [aw=weight_o]

sum loyal boycott power if dem == 1 [aw=weight_a]
sum loyal boycott power  if ind == 1 [aw=weight_a]
sum loyal boycott power  if rep == 1 [aw=weight_a]



***Religion
gen rel_imp = pew_religimp
recode rel_imp 4=1 3=2 2=3 1=4

reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 1 | rel_imp == 2 [aw= weight_a]
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 1 | rel_imp == 2 [aw= weight_a]
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 1 | rel_imp == 2 [aw= weight_a]
reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 3 | rel_imp == 4 [aw= weight_a]
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 3 | rel_imp == 4 [aw= weight_a]
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if rel_imp == 3 | rel_imp == 4 [aw= weight_a]


reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if pew_chura == 5 | pew_chura == 6 [aw= weight_a]
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if pew_chura == 5 | pew_chura == 6 [aw= weight_a]
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if pew_chura == 5 | pew_chura == 6 [aw= weight_a]

reg loyal vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1 if pew_chura <=3 [aw= weight_a]
reg boycott vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if pew_chura <=3 [aw= weight_a]
reg power vlib-vcon prime_is pct_jew black his other_race age femal  BA   Q5_1 Q5_2 Q8_1 Q8_2 Q14_1  if pew_chura <=3 [aw= weight_a]


*GRAPHS
insheet using paper_graph1.csv, clear comma



replace loyal_mean = loyal_mean*100
replace boycott_mean = boycott_mean*100
replace power_mean = power_mean*100 
replace antisem_mean = antisem_mean*100 

replace loyal_lb = loyal_lb*100
replace boycott_lb = boycott_lb*100
replace power_lb = power_lb*100 
replace antisem_lb = antisem_lb*100 

replace loyal_ub = loyal_ub*100
replace boycott_ub = boycott_ub*100
replace power_ub = power_ub*100 
replace antisem_ub = antisem_ub*100 


***Fig 1. ALL, PRIME v NO PRIME
keep if all == 1
replace ideo= ideo+.1 if prime == 1
replace ideo = ideo-.1 if prime ==0

twoway(scatter loyal_mean ideo if  prime == 0, ms(square) mc(gs10%80)) ///
(scatter loyal_mean ideo if prime ==1,  mc(black)) ///
(rspike loyal_lb loyal_ub ideo if prime == 0, lwidth(thin) lc(gs10)) ///
(rspike loyal_lb loyal_ub ideo if prime == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "No Prime" 2 "Prime" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(A)", size(medium)) subtitle(More Loyal to Israel) ylabel(0(10)50) saving(gn1_1.gph, replace)


  twoway(scatter boycott_mean ideo if  prime == 0, ms(square) mc(gs10%80)) ///
(scatter boycott_mean ideo if prime ==1, mc(black)) ///
(rspike boycott_lb boycott_ub ideo if prime == 0, lwidth(thin) lc(gs10)) ///
(rspike boycott_lb boycott_ub ideo if prime == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "No Prime" 2 "Prime" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(B)", size(medium)) subtitle(Boycott Jewish Businesses) ylabel(0(10)50) saving(gn1_2.gph, replace)


  
  twoway(scatter power_mean ideo if  prime == 0, ms(square) mc(gs10%80)) ///
(scatter power_mean ideo if prime ==1, mc(black)) ///
(rspike power_lb power_ub ideo if prime == 0, lwidth(thin) lc(gs10)) ///
(rspike power_lb power_ub ideo if prime == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "No Prime" 2 "Prime" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(C)", size(medium)) subtitle(Too Much Power) ylabel(0(10)50) saving(gn1_3.gph, replace)


graph combine gn1_1.gph gn1_2.gph gn1_3.gph, rows(1) xsize(8) ysize(3) iscale(1.4) ///
l1title(Pct. Agree, size(large)) 
graph export nfig1.pdf, replace

*GRAPHS

insheet using paper_graph1.csv, clear comma



replace loyal_mean = loyal_mean*100
replace boycott_mean = boycott_mean*100
replace power_mean = power_mean*100 
replace antisem_mean = antisem_mean*100 

replace loyal_lb = loyal_lb*100
replace boycott_lb = boycott_lb*100
replace power_lb = power_lb*100 
replace antisem_lb = antisem_lb*100 

replace loyal_ub = loyal_ub*100
replace boycott_ub = boycott_ub*100
replace power_ub = power_ub*100 
replace antisem_ub = antisem_ub*100 


***Fig 2. Young Vs Old 
keep if prime == .
replace ideo= ideo+.1 if young == 1
replace ideo = ideo-.1 if young ==0


twoway(scatter loyal_mean ideo if  young ==0 , ms(square) mc(gs10%80)) ///
(scatter loyal_mean ideo if young ==1,  mc(black)) ///
(rspike loyal_lb loyal_ub ideo if young == 0, lwidth(thin) lc(gs10)) ///
(rspike loyal_lb loyal_ub ideo if young == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Over 30" 2 "18-30" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(A)", size(medium)) subtitle(More Loyal to Israel) ylabel(0(10)50) saving(gn2_1.gph, replace)


  twoway(scatter boycott_mean ideo if  young == 0, ms(square) mc(gs10%80)) ///
(scatter boycott_mean ideo if young ==1, mc(black)) ///
(rspike boycott_lb boycott_ub ideo if young == 0, lwidth(thin) lc(gs10)) ///
(rspike boycott_lb boycott_ub ideo if young == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Over 30" 2 "18-30" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(B)", size(medium)) subtitle(Boycott Jewish Businesses) ylabel(0(10)50) saving(gn2_2.gph, replace)


  
  twoway(scatter power_mean ideo if  young == 0, ms(square) mc(gs10%80)) ///
(scatter power_mean ideo if young ==1, mc(black)) ///
(rspike power_lb power_ub ideo if young == 0, lwidth(thin) lc(gs10)) ///
(rspike power_lb power_ub ideo if young == 1, lwidth(thin) lc(black)), ///
yscale(noextend) xscale(noextend)  xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks) ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Over 30" 2 "18-30" ) size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
  title("(C)", size(medium)) subtitle(Too Much Power) ylabel(0(10)50) saving(gn2_3.gph, replace)


graph combine gn2_1.gph gn2_2.gph gn2_3.gph, rows(1) xsize(8) ysize(3) iscale(1.4) ///
l1title(Pct. Agree, size(large)) 
graph export nfig2.pdf, replace

********



*JEWS THINK THE OVERT MEASURES ARE ANTISEMTIC 

u TUFT0009_OUTPUT.DTA, clear



tab q22_a if q22_a != 3 [aw=weight_o]
tab q22_b if q22_b != 3 [aw=weight_o]
tab q22_c if q22_c != 3 [aw=weight_o]


tab q22_a  [aw=weight_o]
tab q22_b   [aw=weight_o]
tab q22_c  [aw=weight_o]


tab q22_a if q22_a !=3 [aw=weight_a]
tab q22_b if q22_b !=3 [aw=weight_a]
tab q22_c if q22_c !=3 [aw=weight_a]


***Are they tied to Israel/Palestine policy?
*Mostly not



gen just_ip = 0 if q21_1 == 1 | q21_2 == 1 | q21_3 == 1 | q21_4 == 1 | q21_5 == 1 | q21_6 == 1  
replace just_ip = 1 if q21_1 ==1 & q21_2 == 2 & q21_3 == 2 & q21_4 == 2 & q21_5 == 2 & q21_6 == 2 

recode q21_1 2=0, gen(israel_palestine)
recode q21_2 2=0, gen(news)
recode q21_3 2=0, gen(entertainment)
recode q21_4 2=0, gen(domestic_politics)
recode q21_5 2=0, gen(finance)
recode q21_6 2=0, gen(agricultural)

replace israel = israel*100
replace news = news*100
replace entert = enter*100
replace domest = domest*100
replace finance = finance*100
replace agri = agri*100 
replace just_ip = just_ip*100

graph bar (mean) israel_pa (mean) news (mean) enter (mean) domest (mean) ///
finance (mean) agric (mean) just_ [aweight = weight_a],  bargap(10)  ///
bar(1, lcolor(black) fcolor(black%80)) bar(2, lcolor(black) ///
fcolor(black%80)) bar(3, lcolor(black) fcolor(black%80)) ///
bar(4, lcolor(black)  fcolor(black%80)) bar(5, lcolor(black) fcolor(black%80)) ///
bar(6, lcolor(black) fcolor(black%80)) bar(7, lcolor(red) fcolor(red%80)) ///
legend(off) ytitle("") ///
title(Ages 18-30) plotregion(style(none)) ///
 yscale(noextend) showyvars yvaroptions(relabel(1 "Isr./Palest." ///
 2 "News Media" 3 "Entertainment" 4 "Dom. Politics" 5 "Finance" ///
 6 "Agriculture" 7 "ONLY Isr./Palest.") label(angle(forty_five))) saving(power1.gph, replace)

 graph bar (mean) israel_pa (mean) news (mean) enter (mean) domest (mean) ///
finance (mean) agric (mean) just_  if age > 30 [aweight = weight_o],  bargap(10)  ///
bar(1, lcolor(black) fcolor(black%80)) bar(2, lcolor(black) ///
fcolor(black%80)) bar(3, lcolor(black) fcolor(black%80)) ///
bar(4, lcolor(black)  fcolor(black%80)) bar(5, lcolor(black) fcolor(black%80)) ///
bar(6, lcolor(black) fcolor(black%80)) bar(7, lcolor(red) fcolor(red%80)) ///
legend(off) ytitle("") ///
title(Ages 31+) plotregion(style(none)) ///
 yscale(noextend) showyvars yvaroptions(relabel(1 "Isr./Palest." ///
 2 "News Media" 3 "Entertainment" 4 "Dom. Politics" 5 "Finance" ///
 6 "Agriculture" 7 "ONLY Isr./Palest.") label(angle(forty_five)))  saving(power2.gph, replace)


 
 graph bar (mean) israel_pa (mean) news (mean) enter (mean) domest (mean) ///
finance (mean) agric (mean) just_  if ideo7 <4 [aw=weight_o],  bargap(10)  ///
bar(1, lcolor(black) fcolor(black%80)) bar(2, lcolor(black) ///
fcolor(black%80)) bar(3, lcolor(black) fcolor(black%80)) ///
bar(4, lcolor(black)  fcolor(black%80)) bar(5, lcolor(black) fcolor(black%80)) ///
bar(6, lcolor(black) fcolor(black%80)) bar(7, lcolor(red) fcolor(red%80)) ///
legend(off) ytitle("")	 ylabel(0(20)60) ///
title(Liberals) plotregion(style(none)) ///
 yscale(noextend) showyvars yvaroptions(relabel(1 "Isr./Palest." ///
 2 "News Media" 3 "Entertainment" 4 "Dom. Politics" 5 "Finance" ///
 6 "Agriculture" 7 "ONLY Isr./Palest.") label(angle(forty_five)))  saving(power5.gph, replace)


  graph bar (mean) israel_pa (mean) news (mean) enter (mean) domest (mean) ///
finance (mean) agric (mean) just_  if ideo7 >4 [aweight = weight_o],  bargap(10)  ///
bar(1, lcolor(black) fcolor(black%80)) bar(2, lcolor(black) ///
fcolor(black%80)) bar(3, lcolor(black) fcolor(black%80)) ///
bar(4, lcolor(black)  fcolor(black%80)) bar(5, lcolor(black) fcolor(black%80)) ///
bar(6, lcolor(black) fcolor(black%80)) bar(7, lcolor(red) fcolor(red%80)) ///
legend(off) ytitle(Pct. Citing Reason) ylabel(0(20)60) ///
title(Conservatives) plotregion(style(none)) ///
 yscale(noextend) showyvars yvaroptions(relabel(1 "Isr./Palest." ///
 2 "News Media" 3 "Entertainment" 4 "Dom. Politics" 5 "Finance" ///
 6 "Agriculture" 7 "ONLY Isr./Palest.") label(angle(forty_five)))  saving(power6.gph, replace)
 
 graph combine power1.gph power2.gph power5.gph power6.gph, ///
 rows(3) ysize(8) xsize(8)
 graph export power.pdf, replace
 
 sum just [aw=weight_a]
 sum just if age > 30 [aw=weight_o]
 sum just if ideo7 <4 [aw=weight_o]
 sum just if ideo7 > 4 [aw=weight_o]
 
 
 ********************************************************************
 ********************************************************************
 *DOUBLE STANDARDS
 

 

u TUFT0009_OUTPUT.DTA, clear

recode q2_mult* (2=0)
ren q2_mult_1 socialist
ren q2_mult_2 leftist
ren q2_mult_3 progressive
ren q2_mult_4 libertarian
ren q2_mult_5 alt_right
ren q2_mult_6 christian_con

gen college_4yr = 1 if q1 == 2 | q1 == 3
recode college .=0
gen college_degree  = 1 if educ == 5 | edu == 6
recode college_degree . =0
gen BA = 1 if college_degree ==1 | college_4yr == 1
recode BA . =0
label var BA "College"


*controlling for previous randomizations
gen Q5_1 = 1 if Q5_7 == 1
gen Q5_2 = 1 if Q5_7 == 2
recode Q5_1 Q5_2 (.=0)
gen Q8_1 =1 if Q8_13 == 1
gen Q8_2 = 1 if Q8_13 ==2
recode Q8_1 Q8_2 (.=0)
gen Q14_1 =1 if Q14_15 == 1
recode Q14_1 .=0

gen black = race == 2
gen hisp = race == 3
gen white = race == 1
gen asian = race == 4
gen other_race =1 if race >4
replace other_race = 0 if race <=4
replace other_race = 1 if asian ==1 

gen female = gende == 2
*THese vars are Q5_1 Q5_2 Q8_1 Q8_2 Q14

replace age = age/10



gen muslim_denounce  = q14
recode muslim 1 2 = 1 3 4 5 = 0

gen jewish_denounce = q15
recode jewish_den 1 2 =1 3 4 5 =0

*drop Jews and Muslims
drop if relig == 5 | relig ==6

gen vlib = ideo7 == 1
gen mlib = ideo7 == 2
gen slib = ideo7 == 3
gen scon = ideo7 == 5
gen mcon = ideo7 == 6
gen vcon = ideo7 == 7
recode vlib-vcon (0=.) if ideo7 ==. 

merge m:1 inputstate using pct_jew_pop
drop _merge


label var vlib "Very Lib."
label var mlib "Liberal"
label var slib "Mod. Lib."
label var scon "Mod. Con."
label var mcon "Conservative"
label var vcon "Very Con."
label var black "Black"
label var his "Latinx"
label var asia "Asian"
label var other_r "Other Race"
label var age "Age"
label var college_4 "4-year College"
label var fema "Female"
label var musl "Muslims Denounce"
label var jew "Jews Denounce"


gen denounce  = 1 if jewish_denounce == 1 | muslim_denounce == 1
replace denounce = 0 if jewish_denounce == 0 | muslim_denounce == 0
gen jm_condition = 1 if jewish_denounce != . 
replace jm_condition  = 0 if muslim_denounce != . 


*TABLE 5

reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 2 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 3 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 4 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 5 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 6 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 7 [aw=weight_a]



reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if leftist == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if socialist == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if progressive == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if libert == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if christian_c == 1 [aw=weight_a]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if alt_rig == 1 [aw=weight_a]


reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 2 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 3 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 4 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 5 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 6 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if ideo7 == 7 [aw=weight_o]



reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if leftist == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if socialist == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if progressive == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if libert == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if christian_c == 1 [aw=weight_o]
reg denounce jm_condition pct_jew black his other_race age femal  BA  Q5_1 Q5_2 Q8_1 Q8_2  if alt_rig == 1 [aw=weight_o]





*For graph
bysort ideo7: ci mean jewish muslim  [aw=weight_a]
bysort ideo7: ci mean jewish muslim if age >3  [aw=weight_o]
bysort ideo7: ci mean jewish muslim [aw=weight_o]

insheet using paper_graph_double1.csv, clear comma




replace mean = mean*100
replace lb = lb*100
replace ub = ub*100


replace ideo= ideo+.1 if jewish == 1
replace ideo = ideo-.1 if jewish ==0

twoway(scatter mean ideo if young == 1 & jewish ==1, mc(black) ms(square)) ///
(scatter mean ideo if young == 1 & jewish ==0 , mc(gs10%80) ms(circle)) ///
(rspike lb ub ideo if young == 1 & jewish == 1, lc(black)) ///
(rspike lb ub ideo if young == 1 & jewish ==0 , lc(gs10%80)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") title("(B)", size(medium)) ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews Should Denounce" 2 "Muslims Should Denounce") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
subtitle(Adults 18-30) ylabel(0(20)80) saving(new_jm1.gph, replace)

twoway(scatter mean ideo if young == . & jewish ==1, mc(black) ms(square)) ///
(scatter mean ideo if young == . & jewish ==0 , mc(gs10%80) ms(circle)) ///
(rspike lb ub ideo if young == . & jewish == 1, lc(black)) ///
(rspike lb ub ideo if young == . & jewish ==0 , lc(gs10%80)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") title("(A)", size(medium)) ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews Should Denounce" 2 "Muslims Should Denounce") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
subtitle(All adults) ylabel(0(20)80) saving(new_jm2.gph, replace)




graph combine new_jm2.gph new_jm1.gph, rows(1) xsize(8) ysize(4) iscale(1.1) l1title(Pct. Agree)
graph export double1.pdf, replace


*CATHOLICS, INDIANS, JEWS


u TUFT0009_OUTPUT.DTA, clear

recode q2_mult* (2=0)
ren q2_mult_1 socialist
ren q2_mult_2 leftist
ren q2_mult_3 progressive
ren q2_mult_4 libertarian
ren q2_mult_5 alt_right
ren q2_mult_6 christian_con

gen college_4yr = 1 if q1 == 2 | q1 == 3
recode college .=0
gen college_degree  = 1 if educ == 5 | edu == 6
recode college_degree . =0
gen BA = 1 if college_degree ==1 | college_4yr == 1
recode BA . =0
label var BA "College"


*controlling for previous randomizations
gen Q5_1 = 1 if Q5_7 == 1
gen Q5_2 = 1 if Q5_7 == 2
recode Q5_1 Q5_2 (.=0)
gen Q8_1 =1 if Q8_13 == 1
gen Q8_2 = 1 if Q8_13 ==2
recode Q8_1 Q8_2 (.=0)
gen Q14_1 =1 if Q14_15 == 1
recode Q14_1 .=0

gen black = race == 2
gen hisp = race == 3
gen white = race == 1
gen asian = race == 4
gen other_race =1 if race >4
replace other_race = 0 if race <=4
replace other_race = 1 if asian ==1 

gen female = gende == 2
*THese vars are Q5_1 Q5_2 Q8_1 Q8_2 Q14

replace age = age/10




gen vlib = ideo7 == 1
gen mlib = ideo7 == 2
gen slib = ideo7 == 3
gen scon = ideo7 == 5
gen mcon = ideo7 == 6
gen vcon = ideo7 == 7
recode vlib-vcon (0=.) if ideo7 ==. 

merge m:1 inputstate using pct_jew_pop
drop _merge


label var vlib "Very Lib."
label var mlib "Liberal"
label var slib "Mod. Lib."
label var scon "Mod. Con."
label var mcon "Conservative"
label var vcon "Very Con."
label var black "Black"
label var his "Latinx"
label var asia "Asian"
label var other_r "Other Race"
label var age "Age"
label var college_4 "4-year College"
label var fema "Female"


gen cath_account = q8
recode cath_account  1 2 =1 3 4 5 =0

gen cath_domore = q9
recode cath_domore 1 2 =1 3 4 5 =0 

gen indian_account = q10
recode indian_account 1 2 =1 3 4 5 =0

gen indian_domore = q11
recode indian_domore 1 2 = 1 3 4 5 = 0

gen jewish_account = q12
recode jewish_account 1 2 =1 3 4 5 =0

gen jewish_domore = q13
recode jewish_domore 1 2 = 1 3 4 5 =0

 gen account = 1 if cath_account ==1 | indian_account == 1 | jewish_account ==1
 replace account = 0 if cath_account == 0 | indian_account == 0 | jewish_account == 0 
 gen domore = 1 if cath_domore ==1 | indian_domore == 1 | jewish_domore ==1
 replace domore = 0 if cath_domore == 0 | indian_domore == 0 | jewish_domore == 0 
 
 gen condition_j = 1 if jewish_account != .
 replace condition_j = 0 if jewish_account == . 
 
 gen condition_c = 1 if cath_account != .
 replace condition_c = 0 if cath_account == . 
  gen condition_i = 1 if indian_accou != . 
  replace condition_i = 0 if indian_acc == . 


*RELIG 2= catholic, 5=jewish, 8= hindu

drop if relig == 2 | relig == 5 | relig == 8
*FOR GRAPHS
bysort ideo7: ci mean cath_domore indian_domore jewish_domore [aw=weight_a]
bysort ideo7: ci mean cath_domore indian_domore jewish_domore [aw=weight_o]

bysort ideo7: ci mean cath_account indian_account jewish_account [aw=weight_a]
bysort ideo7: ci mean cath_account indian_account jewish_account [aw=weight_o]

*TABLE 5
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==2 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==3 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==4 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==5 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==6 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==7 [aw=weight_a]

reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if leftist ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if socialist ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if progres ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if liber ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if christian_c ==1 [aw=weight_a]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if alt_r ==1 [aw=weight_a]


reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==2 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==3 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==4 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==5 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==6 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==7 [aw=weight_o]

reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if leftist ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if socialist ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if progres ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if liber ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if christian_c ==1 [aw=weight_o]
reg domore condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if alt_r ==1 [aw=weight_o]


reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==2 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==3 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==4 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==5 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==6 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==7 [aw=weight_a]

reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if leftist ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if socialist ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if progres ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if liber ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if christian_c ==1 [aw=weight_a]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if alt_r ==1 [aw=weight_a]


reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==2 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==3 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==4 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==5 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==6 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if ideo7 ==7 [aw=weight_o]

reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if leftist ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if socialist ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if progres ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if liber ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if christian_c ==1 [aw=weight_o]
reg account condition_j condition_c pct_jew black his other_race age femal BA Q5_1 Q5_2 if alt_r ==1 [aw=weight_o]



*FOR GRAPHS
bysort ideo7: ci mean cath_domore indian_domore jewish_domore [aw=weight_a]
bysort ideo7: ci mean cath_domore indian_domore jewish_domore [aw=weight_o]

bysort ideo7: ci mean cath_account indian_account jewish_account [aw=weight_a]
bysort ideo7: ci mean cath_account indian_account jewish_account [aw=weight_o]





insheet using 	experiment2_new.csv, clear comma

replace domore_mean = domore_mean*100
replace domore_lb = domore_lb*100
replace domore_ub = domore_ub*100 
replace accountable_mean = accountable_mean*100
replace accountable_lb = accountable_lb*100
replace accountable_ub = accountable_ub*100 

replace ideo = ideo-.1 if indian ==1
replace ideo = ideo+.1 if cath == 1

twoway(scatter domore_mean ideo if jewish == 1 & young == 0, mc(black) ms(square)) ///
(scatter domore_mean ideo if indian == 1 & young == 0, mc(gs6) ms(circle)) ///
(scatter domore_mean ideo if catholic == 1 & young == 0, mc(gs12) ms(triangle)) ///
(rspike domore_lb domore_ub ideo if jewish ==1 & young ==0,  lc(black)) ///
(rspike domore_lb domore_ub ideo if indian == 1 & young == 0, lc(gs6)) ///
(rspike domore_lb domore_ub ideo if catholic == 1 & young == 0 , lc(gs12)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews" 2 "Indians" 3 "Catholics") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
title("(A)", size(medium)) subtitle("DO MORE, All adults") ylabel(0(20)80) saving(d2_1_new.gph, replace)



twoway(scatter domore_mean ideo if jewish == 1 & young == 1, mc(black) ms(square)) ///
(scatter domore_mean ideo if indian == 1 & young == 1, mc(gs6) ms(circle)) ///
(scatter domore_mean ideo if catholic == 1 & young == 1, mc(gs12) ms(triangle)) ///
(rspike domore_lb domore_ub ideo if jewish ==1 & young == 1,  lc(black)) ///
(rspike domore_lb domore_ub ideo if indian == 1 & young == 1, lc(gs6)) ///
(rspike domore_lb domore_ub ideo if catholic == 1 & young == 1 , lc(gs12)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews" 2 "Indians" 3 "Catholics") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
title("(B)", size(medium)) subtitle("DO MORE, Adults 18-30") ylabel(0(20)80) saving(d2_2_new.gph, replace)


twoway(scatter accountable_mean ideo if jewish == 1 & young == 0, mc(black) ms(square)) ///
(scatter accountable_mean ideo if indian == 1 & young == 0, mc(gs6) ms(circle)) ///
(scatter accountable_mean ideo if catholic == 1 & young == 0, mc(gs12) ms(triangle)) ///
(rspike accountable_lb accountable_ub ideo if jewish ==1 & young ==0,  lc(black)) ///
(rspike accountable_lb accountable_ub ideo if indian == 1 & young == 0, lc(gs6)) ///
(rspike accountable_lb accountable_ub ideo if catholic == 1 & young == 0 , lc(gs12)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews" 2 "Indians" 3 "Catholics") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
title("(C)", size(medium)) subtitle("HELD ACCOUNTABLE, All adults") ylabel(0(20)80) saving(d2_3_new.gph, replace)

twoway(scatter accountable_mean ideo if jewish == 1 & young == 1, mc(black) ms(square)) ///
(scatter accountable_mean ideo if indian == 1 & young == 1, mc(gs6) ms(circle)) ///
(scatter accountable_mean ideo if catholic == 1 & young == 1, mc(gs12) ms(triangle)) ///
(rspike accountable_lb accountable_ub ideo if jewish ==1 & young ==1,  lc(black)) ///
(rspike accountable_lb accountable_ub ideo if indian == 1 & young ==1, lc(gs6)) ///
(rspike accountable_lb accountable_ub ideo if catholic == 1 & young == 1 , lc(gs12)), ///
yscale(noextend) xscale(noextend) xlabel(1 "Lib" 4 "Mod"  7 "Con",  valuelabel ticks)  ///
xtitle("") ytitle("") plotregion(style(none)) ///
legend(on order(1 "Jews" 2 "Indians" 3 "Catholics") size(small) rows(3) position(11) ring(0) region(lcolor(none))) ///
title("(D)", size(medium)) subtitle("HELD ACCOUNTABLE, Adults 18-30") ylabel(0(20)80) saving(d2_4_new.gph, replace)





graph combine d2_1_new.gph d2_2_new.gph d2_3_new.gph d2_4_new.gph, rows(2) xsize(8) ysize(7) iscale(.6) l1title(Pct. Agree)
graph export experiment2_comb.pdf, replace


 
 
 
 
 
 
 
 
 
 
 
 
 
 